<template>
    <div class="cards-container">
        <div class="header">
            <div class="title">
                <img src="~@/assets/screen/card_icon.png" alt="">
                {{ title }}
            </div>
        </div>
        <div class="contents">
            <slot></slot>
        </div>
    </div>
</template>

<script>
export default {
    name: 'card',
    props: {
        title: {
            type: String,
            default: '标题'
        }
    },
    data() {
        return {};
    },
};
</script>

<style lang='less' scoped>
.cards-container {
    width: 536px;
    // height: 294px;


    .header {
        width: 100%;
        height: 36px;
        display: flex;
        align-items: center;
        box-sizing: border-box;
        padding-left: 10px;
        color: #fff;
        background: url('~@/assets/screen/card_head.png') no-repeat;
        background-size: 100% 100%;
        .title{
            display: flex;
            align-items: center;
            gap: 5px;
        }
    }

    .contents {
        width: 100%;
        height: calc(100% - 36px);
        box-sizing: border-box;
        padding: 0 10px;
        background: url('~@/assets/screen/card_con.png') no-repeat;
        background-size: 100% 100%;
    }
}
</style>